#include <string.h>
#include <iostream>
using namespace std;

class Employee {
public:
    Employee(int id, const char * name, float salary)
    : _id(id)
    , _salary(salary)
    {
        strcpy(_name, name);
    }
    
    void print() const  {
        cout << "id:" << _id << endl;
        cout << "name:" << _name << endl;
        cout << "salary:" << _salary << endl;
    }

private:
    int _id;           //员工工牌
    char _name[20];    //员工姓名
    float _salary;     //员工薪资,这个是隐私信息，尤其需要保密，不能随便访问
};

int main() {
    Employee e1(100, "Jerry", 15000);
    e1.print();
    return 0;
}
